{% extends 'base.html' %}

{% block head %}
<script src="/static/demo.js" type="text/javascript"></script>

{% endblock %}

{% block content %}

	<div id="top">
      <p>!! CRYPT CHAT !!!</p>
    </div>
	<div id="center">

        Channel based chat with strong encryption using <a href="https://github.com/daviddahl/domcrypt">domcrypt</a><BR>
	Requires the <a href="http://mozilla.ddahl.com/domcrypt/extension/built/domcrypt.xpi">Firefox Plugin</a> and Firefox 4 or newer.
<BR><BR>
	<div id="stepone">
	<div id="generate">
      <h2>1. Generate the key pair</h2>
      <div>
        <button onclick="domcrypt_generate();">Generate Key Pair</button>
      </div>

      <div class="key" id="pubKey"></div>
    </div>
    </div>
	<div id="steptwo"> 

	      <h2>2. Register a new chat </h2>
	Using your name is not advised.<BR>
	<form name="register" action="/register" method="post" id="register">
	<input name="handle" value="your handle"> 
    <input name=pubKey value="" id="pubKeyInput" type="hidden"><BR>
	<br><input type="submit" id="registerbutton" name="registerbutton" value="Register a new chat" ><br>

	<br><br>

	</form>
	</div>
	
    </div>

{% endblock %}